using UnityEngine;

namespace BasicScript.Component
{
	public class RotateObject : MonoBehaviour
	{
		private float curRoration;

		public bool isLeft;

		public float speed = 5f;

		private void LateUpdate()
		{
			if (isLeft)
			{
				curRoration -= Time.deltaTime * speed;
			}
			else
			{
				curRoration += Time.deltaTime * speed;
			}
			base.transform.rotation = Quaternion.Euler(0f, 0f, curRoration);
		}
	}
}
